package com.dc.dao.impl;

import com.dc.base.utils.BaseDao;
import com.dc.dao.MessageDao;

import java.util.List;
import java.util.Map;

public class MessageDaoImpl implements MessageDao {
    BaseDao baseDao=new BaseDao();


    @Override
    public int addMessage(String sql) throws Exception {
        return baseDao.update(sql);
    }

    @Override
    public int updateMessage(String sql) throws Exception {
        return baseDao.update(sql);
    }

    @Override
    public int deleteMessage(String sql) throws Exception {
        return baseDao.update(sql);
    }

    @Override
    public List<Map<String, Object>> selectMessage(String sql, Object[] params) throws Exception {
        return baseDao.query(sql,params);
    }

    @Override
    public List<Map<String, Object>> selectMessageid(String sql) throws Exception {
        return baseDao.query(sql,null);
    }
}
